home *** CD-ROM | disk | FTP | other *** search
/ C/C++ Users Group Library 1996 July / C-C++ Users Group Library July 1996.iso / vol_200 / 293_01 / tofg100.c < prev    next >
C/C++ Source or Header  |  1989-08-23  |  506b  |  29 lines

  1. /*      sample.c
  2.  
  3. Sample ITEX 100 program 
  4.  
  5. */
  6. #include "itex100.h"
  7. #include "stdtyp.h"
  8. #include <stdio.h>
  9. unsigned char buf[256];
  10. main ()
  11. {FILE *fn;
  12.  int i,line;
  13.  char fname[40];
  14. sethdw(0x300,0xa0000L,PSEUDO_COLOR,1);
  15. setdim(512,512,12);
  16. initialize();
  17. sclear(0,WAIT);
  18. printf("Enter file name:");
  19. scanf("%s",fname);
  20. printf("Enter number of line:");
  21. scanf("%d",&line);
  22. fn=fopen(fname,"rb");
  23. for(i=line;i>0;i--){
  24.     fread(buf,1,256,fn);
  25.     bwhline(0,i,256,buf);
  26. }
  27. fclose(fn);
  28. }
  29.